const express = require("express");
const { db } = require("../database");
const { CustomerAuth } = require("../middles");
const { avatar } = require("../upload");
const { sign } = require("../jwt");
const { makePassword, checkPassword } = require("../utils");

const { validate, validators } = require("../validate");

const router = express.Router();
// CustomerAuth 中间件实现对登录用户的验证，如果验证通过，就会有 req.user 属性。
router.use(CustomerAuth);

// router.post();

const registerRouter = (app) => {
  app.use("/address", router);
};

module.exports = { registerRouter };
